package com.ha.auto_skip.service;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;

public class PwBroadcastReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        switch (intent.getAction()) {
            case Intent.ACTION_BOOT_COMPLETED:
                // 服务保活
                context.startService(new Intent(context, SaveService.class));

                break;
            case Intent.ACTION_SHUTDOWN:
                Log.d("关机", "关机");
                break;
        }
    }
}
